# -*- coding: utf-8 -*-
"""
Created on Tue Sep 19 19:41:52 2023

@author: 楠川之木
"""

money=int(input("输入要找的零钱"))
print(int(money/50),int(money%50/2),int(money%50%2/1))